<?php
if($this->session->userdata('admin_type') == 'Panelist'){
	$this -> admin = 'panelist';
}
$this -> load -> view('admin/head');
$this -> load -> view('admin/header');
?>
  <!-- Content -->    
 <div class="space30"></div>
  <div class="container">
    <div class="row"> 
    <div class="col-md-2">
    	<nav class="navbar1">
         <?php if($this->admin == 'panelist'){
				$this->load->view('admin/left_nav1');
				}
				else
				{
				$this->load->view('admin/left_nav');
				}
				?>
    </nav>
    </div>
      <div class="col-md-10">
        <!--form starts-->
        	<div class="form_container">
            		<h4>Manage Application</h4>
                     <!--row starts-->
                    	<div class="row1">
                        <form action="" method="post">
                    	<div class="form-group col-sm-12">
                        	<label for="name2">Search by Event Name</label>
                            <input class="form-control white" id="event_search_name" name="event_search_name" placeholder="Enter Event Name" type="text" value="">
                            <div class="error" id="err-name"></div>
                        </div>
                        <div class="form-group col-sm-12">
                        	<label for="affiliation2">Search by Award Name</label>
                            <input class="form-control white" id="affiliation2" name="award_searc_name" type="text" placeholder="Affiliation" value="">
                            <div class="error" id="err-name"></div>
                        </div>
         				<div class="form-group col-sm-12">
            			<button type="button" class="btn btn-primary" id="send">Search</button>
                        </div>
                        <div class="clearfix"></div>
                        </form>
                    <!--row closed-->
                    <!--row starts-->
                        <div class="row1">
                        <div class="table-responsive">
                          <table border="0" cellspacing="0" cellpadding="0" class="manage_table">
                              <tr>
                                <td width="6%">S.No.</td>
                                <td width="25%">Event Name</td>
                                <td width="18%">Award  Name</td>
                                <td width="22%">Admin Incharge</td>
                                <td width="18%">Chief Panelist</td>
                                <td width="15%" >Status</td>
								<td>&nbsp;</td>
								<td>&nbsp;</td>
								<td>&nbsp;</td>
                              </tr>
							  <?php  if(isset($result) && !empty($result)){$i = 0;
								foreach($result as $temp => $value){  ?>
                              <tr>
                                <td><?php echo $i+1; ?></td>
                                <td><?php if(isset($result1[$i][0]->event_name)) {echo $result1[$i][0]->event_name; }?></td>
                                <td><?php if(isset($result1[$i][0]->award_name)) {echo $result1[$i][0]->award_name;} ?></td>
                                <td><?php if(isset($result2[$i][0]->admin_fullname)) {echo $result2[$i][0]->admin_fullname;} ?></td>
                                <td><?php if(isset($result3[$i][0]->admin_fullname)) {echo $result3[$i][0]->admin_fullname; } ?></td>
                                <td><?php if(isset($result1[$i][0]->award_current_status)) { echo  $result1[$i][0]->award_current_status;}?></td>
                                 <td><a href="">Shortlisted Applicant</a></td>
                                
                                 
                                <td><a href="javascript:void(0);" onclick="openPopUp('<?php echo BASE_URL."/panelist/score?award_id=".$result[0]->award_panelist_award_id; ?>','500','500');">Input Score</a></td>
                                <td><a href="<?php echo BASE_URL.'/panelist/awards?award_id='.$result[0]->award_panelist_award_id; ?>">View</a></td>
                               
								
                                
                              </tr>
                              <?php $i++;}}else{?>
								<tr><td colspan="9">No Record Found</td></tr>
							<?php  }?>
                            </table>
							<div class="space20"></div>
						
</div>
</div>
</div>
         <div class="space30"></div>
              </div>
        <!--row closed-->     
             
        </div>
        <!--form closed-->
         <div class="space30"></div>
        
      </div>
       <div class="clearfix"></div>
    </div>    
  </div>    
  <div class="space20"></div>  
  <div class="space30"></div>  
  
  <!-- Content End -->
<?php $this ->load->view('common/footer'); ?>
<script type="text/javascript">
function openPopUp(url,Width,Height)
{
    winLeft = (screen.width-Width)/2;
    winTop = (screen.height-(Height+110))/2;
    window.open(url,"_blank","toolbar=0,location=0,directories=0,status=1,menubar=0,scrollbars=1,resizable=1,width="+Width+",height="+Height+",left=" + winLeft + ",top=" + winTop);
   
}
</script>